Web services are client and server applications that communicate over the World Wide Web's (WWW) Hypertext Transfer Protocol (HTTP). A web service is a software component provided through a network-accessible endpoint and can be called from other applications. For example, a financial company may have a web service that provides up to the minute stock quotes for customers who do their trading with that financial company. The information provided by the web service can be read from a web page and displayed, or read from a stand-alone application on a customer's desktop computer.
REpresentational State Transfer (REST) is a style of software architecture for distributed systems such as the World Wide Web. REST-style architectures include clients and servers. Clients can initiate requests to the servers, which can process the requests and return appropriate responses. In REST, requests and responses are built around the transfer of representations of resources. A representation of a resource is typically a document that captures the current or intended state of the resource. For example, the resource may be stock quotes.
A RESTful web service is a web service that is implemented using HTTP and the principals of REST. For example, a RESTful web service may be a customer data management web service and may have three resources: (1) a resource that is a list of all customers, (2) a resource that is data for a specific customer, and (3) a resource for adding a customer to the customer data. The RESTful resources can each have a uniform resource identifier (URI), which client applications can use to consume the resource.
A software developer may wish to build a client application to consume the resources provided by a RESTful web service. Typically, the software developer has to have the documentation for the RESTful web service and the documentation for the server hosting the RESTful web service. The software developer usually has to manually sort through the documentation to obtain the appropriate information for creating code for the client application.
In some conventional solutions, a software developer may use a Web Application Description Language (WADL) that describes the RESTful web service to create a client application. The WADL is formatted to describe the resources of the RESTful web service. Traditionally, WADL includes a listing of resources with descriptions of the resources. The resource descriptions are usually nested within each other. Typically, a software developer would manually and recursively drill down through the nested resource descriptions to search for and collect some portion of information for creating the client application code. Generally, software developers must traverse through the nested resource descriptions to gather the appropriate information and combine the information to identify the URI for the resource. In WADL, all types of parameters are mixed in the resource descriptions, which can make it difficult for software developers to distinguish which parameters may be relevant to a client application that is being coded. The conventional solutions (e.g., documentation and WADL) for describing a RESTful web service can result in time-consuming processes for coding client applications to interface with the RESTful web service.